import { Dictionary } from '@/interface/Basic'

export type DeviceENProperties =
  | 'id'
  | 'AAY001'
  | 'AAY002'
  | 'AAY003'
  | 'AAY004'
  | 'AAY005'
  | 'AAY006'
  | 'AAY007'
  | 'AAY008'
  | 'AAY009'
  | 'AAY010'
  | 'AAY011'
  | 'AAY012'
  | 'AAY013'
  | 'AAY014'
  | 'AAY015'
  | 'AAY016'
  | 'AAY017'
  | 'AAY018'
  | 'AAY019'
  | 'AAY020'
  | 'AAY021'
  | 'AAY022'
  | 'AAY023'
  | 'AAY024'
export type DeviceCNProperties =
  | 'ID'
  | '设备编号'
  | '归属部门'
  | '设备名称'
  | '表盘大小'
  | '型号'
  | '数量'
  | '单位'
  | '配对'
  | '精度'
  | '出厂编号'
  | '存放地点'
  | '责任人'
  | '运行情况'
  | '检校日期'
  | '有效期'
  | '有效周期'
  | '类别'
  | '检校费'
  | '备注'
  | '购买日期'
  | '生产厂家'
  | '其他信息1'
  | '保存时间'
  | '操作员'
export type Device = typeof DeviceProperty & { id: string }
export type DeviceProperties = DeviceENProperties
export interface DeviceSetting {
  proper: DeviceProperties
  label: DeviceCNProperties
  type: 'input' | 'select' | 'date' | 'datetime' | 'textarea'
  disabled: boolean
  need?: boolean
}
export const DeviceProperty: Dictionary<string> = {
  id: 'ID',
  AAY001: '设备编号', // input/
  AAY002: '归属部门', // select
  AAY003: '设备名称', // select
  AAY004: '表盘大小',
  AAY005: '型号', // select
  AAY006: '数量',
  AAY007: '单位', // select
  AAY008: '配对',
  AAY009: '精度',
  AAY010: '出厂编号', // input
  AAY011: '存放地点', // select
  AAY012: '责任人', // select
  AAY013: '运行情况',
  AAY014: '检校日期', // date
  AAY015: '有效期', // date
  AAY016: '有效周期',
  AAY017: '类别', // select
  AAY018: '检校费',
  AAY019: '备注',
  AAY020: '购买日期',
  AAY021: '生产厂家',
  AAY022: '其他信息1',
  AAY023: '保存时间',
  AAY024: '操作员' // select
}
export const DevicePropertyWithoutID: Dictionary<string> = {
  AAY001: '设备编号', // input/
  AAY002: '归属部门', // select
  AAY003: '设备名称', // select
  AAY004: '表盘大小',
  AAY005: '型号', // select
  AAY006: '数量',
  AAY007: '单位', // select
  AAY008: '配对',
  AAY009: '精度',
  AAY010: '出厂编号', // input
  AAY011: '存放地点', // select
  AAY012: '责任人', // select
  AAY013: '运行情况',
  AAY014: '检校日期', // date
  AAY015: '有效期', // date
  AAY016: '有效周期',
  AAY017: '类别', // select
  AAY018: '检校费',
  AAY019: '备注',
  AAY020: '购买日期',
  AAY021: '生产厂家',
  AAY022: '其他信息1',
  AAY023: '保存时间',
  AAY024: '操作员' // select
}
export const DeviceSettingList: DeviceSetting[] = [
  { proper: 'id', label: 'ID', type: 'input', disabled: true },
  { proper: 'AAY001', label: '设备编号', type: 'input', disabled: false, need: true },
  { proper: 'AAY002', label: '归属部门', type: 'select', disabled: false },
  { proper: 'AAY003', label: '设备名称', type: 'select', disabled: false, need: true },
  { proper: 'AAY004', label: '表盘大小', type: 'input', disabled: false },
  { proper: 'AAY005', label: '型号', type: 'select', disabled: false },
  { proper: 'AAY006', label: '数量', type: 'input', disabled: false },
  { proper: 'AAY007', label: '单位', type: 'select', disabled: false },
  { proper: 'AAY008', label: '配对', type: 'input', disabled: false },
  { proper: 'AAY009', label: '精度', type: 'input', disabled: false },
  { proper: 'AAY010', label: '出厂编号', type: 'input', disabled: false },
  { proper: 'AAY011', label: '存放地点', type: 'select', disabled: false },
  { proper: 'AAY012', label: '责任人', type: 'select', disabled: false },
  { proper: 'AAY013', label: '运行情况', type: 'input', disabled: false },
  { proper: 'AAY014', label: '检校日期', type: 'date', disabled: false },
  { proper: 'AAY015', label: '有效期', type: 'date', disabled: false },
  { proper: 'AAY016', label: '有效周期', type: 'input', disabled: false },
  { proper: 'AAY017', label: '类别', type: 'select', disabled: false, need: true },
  { proper: 'AAY018', label: '检校费', type: 'input', disabled: false },
  { proper: 'AAY019', label: '备注', type: 'textarea', disabled: false },
  { proper: 'AAY020', label: '购买日期', type: 'date', disabled: false },
  { proper: 'AAY021', label: '生产厂家', type: 'input', disabled: false },
  { proper: 'AAY022', label: '其他信息1', type: 'select', disabled: false },
  { proper: 'AAY023', label: '保存时间', type: 'datetime', disabled: true },
  { proper: 'AAY024', label: '操作员', type: 'select', disabled: true }
]
